export default {
  option: {
    dataset: {
      source: [
        ['score', 'transaction', 'product'],
        [89.3, 58212, 'Matcha Latte'],
        [57.1, 78254, 'Milk Tea'],
        [74.4, 41032, 'Cheese Cocoa'],
        [50.1, 12755, 'Cheese Brownie'],
        [89.7, 20145, 'Matcha Cocoa'],
        [68.1, 79146, 'Tea'],
        [19.6, 91852, 'Orange Juice'],
        [10.6, 101852, 'Lemon Juice'],
        [32.7, 20112, 'Walnut Brownie']
      ]
    },
    title: [{
      text: 'Top20 实时在线交易额',
      // subtext: '总计 ',
      left: '50%',
      textAlign: 'center',
      textStyle: {
        color: '#2512ff',
        fontSize: 20,
        lineHeight: 50
      }
    }],
    grid: {containLabel: true},
    xAxis: {name: '交易额'},
    yAxis: {type: 'category'},
    visualMap: {
      orient: 'horizontal',
      left: 'center',
      min: 10,
      max: 100,
      text: ['High Score', 'Low Score'],
      // Map the score column to color
      dimension: 0,
      inRange: {
        color: ['#D7DA8B', '#E15457']
      }
    },
    series: [
      {
        name: '网红大赛(交易额)',
        type: 'bar',
        label: {
          normal: {
            position: 'right',
            show: true
          }
        },
        encode: {
          // Map the "transaction" column to X axis.
          x: 'transaction',
          // Map the "product" column to Y axis
          y: 'product'
        }
      }
    ]
  }, //end option

  option2: {
    dataset: {
      source: [
        ['score', 'amount', 'product'],
        [89.3, 58212, 'Matcha Latte'],
        [57.1, 78254, 'Milk Tea'],
        [74.4, 41032, 'Cheese Cocoa'],
        [50.1, 12755, 'Cheese Brownie'],
        [89.7, 20145, 'Matcha Cocoa'],
        [68.1, 79146, 'Tea'],
        [19.6, 91852, 'Orange Juice'],
        [10.6, 101852, 'Lemon Juice'],
        [32.7, 20112, 'Walnut Brownie']
      ]
    },
    title: [{
      text: 'Top 20 实时在线交易数量',
      // subtext: '总计 ',
      left: '50%',
      textAlign: 'center',
      textStyle: {
        color: '#2512ff',
        fontSize: 20,
        lineHeight: 50
      }
    }],
    grid: {containLabel: true},
    xAxis: {name: '成交数量'},
    yAxis: {type: 'category'},
    visualMap: {
      orient: 'horizontal',
      left: 'center',
      min: 10,
      max: 100,
      text: ['High Score', 'Low Score'],
      // Map the score column to color
      dimension: 0,
      inRange: {
        color: ['#D7DA8B', '#E15457']
        // color: ['#000000', '#FFFFFF']
      }
    },
    series: [
      {
        name: '网红大赛(交易件)',
        type: 'bar',
        label: {
          normal: {
            position: 'right',
            show: true
          }
        },
        encode: {
          // Map the "amount" column to X axis.
          x: 'amount',
          // Map the "product" column to Y axis
          y: 'product'
        }
      }
    ]
  } //end option2
}
